package app.datavalue;

public enum ContentGenerationMetod 
{
	Static(0),
	FromUrl(1);
	
	private final int code;
	
	ContentGenerationMetod( int code )
	{
		this.code = code;
	}
	
	public int toInt() { return code; }

    public static ContentGenerationMetod fromInt(int code) 
    {
        switch (code) {
        case 0: return Static;
        case 1: return FromUrl;
        default: throw new RuntimeException("Unknown color code");
    }

    }	
	
}
